<template>
	<view>
		<button :loading="loading" open-type="getAuthorize" @click="getUserInfo" class="login-btn">支付宝账号快速登录</button>
	</view>
</template>

<script>
	import {
		login
	} from '@/api/index.js'
	export default {
		data() {
			return {
				loading: false
			};
		},
		onShow() {},
		onLoad() {
			// uni.request({
			// 	url:'https://app.zhwillsbank.com/login/phonePassLogin'
			// })
			// this.zzlogin()
		},
		methods: {
			//#ifdef MP-ALIPAY
			getUserInfo() {
				uni.getAuthCode({
					scopes: 'auth_base', // 主动授权（弹框）：auth_user，静默授权（不弹框）：auth_base
					success: (res) => {
						console.log(res);
					},
				});
			},
			//#endif
			zzlogin() {
				console.log(124313);
				login({
					phone: '171680251497',
					password: '123123'
				}).then(res => {
					console.log(res);
				})
			}
		}
	}
</script>
<style lang="scss" scoped>
	.s {
		background-color: blue;
	}

	.aaa {
		background-color: blue;
	}

	.login-btn {
		width: 665rpx;
		height: 100rpx;
		background-color: RGBA(83, 179, 217, 1);
		color: #fff;
		border-radius: 50rpx;
		line-height: 100rpx;
	}
</style>
